import unittest
from api.login import LoginAPI
from common.common_assert import common_assert

class TestLoginAPI(unittest.TestCase):
    def test01_success(self):
        response = LoginAPI().login({"mobile": 13800000002,"password":123456})
        print(response.json())
        common_assert(self,response)
    def test02_mobile_error(self):
        response = LoginAPI().login({"mobile":13866778899,"password":123456})
        print(response.json())
        common_assert(self,response,200,False,20001,"错误")
    def test03_password_error(self):
        response = LoginAPI().login({"mobile":13800000002,"password":123457})
        print(response.json())
        common_assert(self, response, 200, False, 20001, "错误")
